package com.lagou.util;

/**
 * @author bobcheng
 * @date 2020/6/15
 */
public class TransportIPUtil {

    private TransportIPUtil() {
    }

    private static final ThreadLocal<String> holder = new ThreadLocal<String>();

    public static String getIp() {
        return holder.get();
    }

    public static void setIp(String ip) {
        holder.set(ip);
    }

    public static void clear() {
        holder.remove();
    }
}
